import Vue from 'vue'
import Router from 'vue-router'
import Login from  '../view/login/Login'
import Register from '../view/register/register'
import userManage from '../view/admin/userManage/userManage'
import uploadFomr from '../components/upload-form/upload-form'
import Home from '../view/home/Home'
import dataUpload from '../view/operation/dataUpload/dataUpload'
import dataSetManage from '../view/operation/dataSetManage/dataSetManage'
import checkModel from '../view/admin/checkModel'
//import Login from '../components/login-form/login-form'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'Login',
      component: Login
    },
    {
      path:'/register',
      name:'Register',
      component:Register
    },
    {
      path:'/home',
      name:'Home',
      component:Home,
      children:[{
        path:'/uploadForm',
        name:'uploadForm',
        component:uploadFomr,
      },
      ]
    },
    {
      path:'/operation/dataUpload',
      name:'dataUpload',
      meta:{
        icon:'',
        title:'数据集上传',
      },
      component:dataUpload,
    },
    {
      path:'/operation/dataSetManage',
      name:'dataSetManage',
      meta:{
        icon:'',
        title:'数据集管理'
      },
      component:dataSetManage,
    },
    {
      path:'/admin/checkModel',
      name:'checkModel',
      meta:{
        icon:'',
        title:'模型审核',
      },
      component:checkModel,
    },
    {
      path:'/admin/userManage',
      name:'userManage',
      meta:{
        icon:'' ,
        title:'用户管理',
      },
      component:userManage
    }
  ]
})
